package com.team11.server.pojo.dto;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import io.swagger.annotations.ApiOperation;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDate;
import java.time.LocalTime;

@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiOperation("项目考勤记录表")
public class ProjectAttendance {

    @ApiModelProperty(value = "日期")
    @TableField("kc_date")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "Asia/Shanghai")
    private LocalDate kcDate;

    @ApiModelProperty(value = "项目组名称")
    @TableField("p_name")
    private String pName;

    @ApiModelProperty(value = "院系")
    @TableField("c_department")
    private String cDepartment;

    @ApiModelProperty(value = "专业")
    @TableField("c_major")
    private String cMajor;

    @ApiModelProperty(value = "年级")
    @TableField("c_grade")
    private String cGrade;

    @ApiModelProperty(value = "班级")
    @TableField("c_class")
    private String cClass;

    @ApiModelProperty(value = "项目名称")
    @TableField("kc_name")
    private String kcName;

    @ApiModelProperty(value = "教师姓名")
    @TableField("t_name")
    private String tName;

    @ApiModelProperty(value = "实训老师")
    @TableField("kc_teacher")
    private String kcTeacher;

    @ApiModelProperty(value = "学号")
    @TableField("s_id")
    private String sNumber;

//    @ApiModelProperty(value = "学生id")
//    @TableField("sid")
//    private String sId;

    @ApiModelProperty(value = "学生姓名")
    @TableField("s_name")
    private String sName;

    @ApiModelProperty(value = "应签到时间")
    @TableField("kc_in_time")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(pattern = "HH:mm:ss", timezone = "Asia/Shanghai")
    private LocalTime kcInTime;

    @ApiModelProperty(value = "应签退时间")
    @TableField("kc_out_time")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(pattern = "HH:mm:ss", timezone = "Asia/Shanghai")
    private LocalTime kcOutTime;

    @ApiModelProperty(value = "实签到")
    @TableField("a_real_in")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(pattern = "HH:mm:ss", timezone = "Asia/Shanghai")
    private LocalTime aRealIn;

    @ApiModelProperty(value = "实签退")
    @TableField("a_real_out")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(pattern = "HH:mm:ss", timezone = "Asia/Shanghai")
    private LocalTime aRealOut;

    @ApiModelProperty(value = "考勤情况")
    @TableField("a_state")
    private Integer aState;
}
